﻿

using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

namespace Vehicle.DAL
{   
    /// <summary>
    /// Copyright (C) M-Tear团队
    /// 文 件 名：Permissions.cs
    /// 版    本：v1.00.0000
    /// 创建标识：2009-08-027    Created by 杨光远 V1.00.0000
    /// 功能说明：Permissions表数据层类（继承于数据层基类)
    /// 注意事项：无
    /// 
    /// 更新记录：
    /// 
    /// </summary>
    public class Permissions : DAL.Base_DAL, Vehicle.Interface.IPermissions
    {

       /// <summary>
        ///  绑定页面DataList控件
       /// </summary>
        /// <param name="DAL">DataList控件对象</param>
        public void DataListBind(DataList DAL)
        {
            Vehicle.Model.ComponentsInfo m_Components = new Vehicle.Model.ComponentsInfo();
            m_Components.tableName="Permissions";
            m_Components.condition="P_Parent";
            m_Components.result="0";
            m_Components.order="P_Parent";
            DAL.DataSource = GetModel(m_Components);
            DAL.DataBind();
        }
        /// <summary>
        ///  获得左边下拉菜单节点
        /// </summary>
        /// <param name="m_ComponentsInfo">通用实体对象</param>
        /// <returns></returns>
        public DataTable GetLeftList(Model.ComponentsInfo m_ComponentsInfo)
        {
            string SpName = "Permissions_Left";
            object[] _object = new object[] { 0,m_ComponentsInfo.startIndex};
            return SqlHelper.GetDataTable(SpName, _object);
        }


    }
}
